import Vue from 'vue'
import App from './App'
import VueRouter from 'vue-router'
import Vuex from 'vuex'
import VueResource from 'vue-resource'
import './assets/global.css'
import './assets/index.css'

import Index from './views/Index.vue'
import Activities from './views/Activities.vue'
import Mine from './views/Mine.vue'
import Test from './views/Test.vue'

Vue.use(VueResource);
Vue.use(Vuex);
Vue.use(VueRouter);

var router = new VueRouter({
    history: true
});

router.map({
    '/index': {
        component: Index
    },
    '/activities': {
        component: Activities
    },
    '/mine': {
        component: Mine
    },
    '/test': {
        component: Test
    }
});

/* eslint-disable no-new */
router.redirect({
    '/': '/index'
})

router.start(App, '#app');
